#ifndef RRRASTERIZER_H
#define RRRASTERIZER_H

#include "rrprim.h"

#define RASTER_MAX 500000

class RRRasterizer
{
private:
    int points_index;
    void rrLineRast(int s, int t);
    void rrLineStripRast();
    void rrLineLoopRast();
    void rrTriangleRast(int s, int t, int u);
    void rrHLineRast(int x0, int x1, int Y);
    void rrPolygonRast();
    void rrTriangleInterpolation(int X, int Y);
    RRFragment points[RASTER_MAX];
    void rrAddPoint(int X, int Y);
    int current_triangle[3];

public:
    explicit RRRasterizer();
    RRPrim prim;
    void rrSetPrim(RRPrim &arg);
    void rrRast();
    int rrGetPointsNum();
    RRFragment rrGetPoint(int index);
};

#endif // RRRASTERIZER_H
